﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using VisionCore;

namespace COER
{
    public partial class FormManual : Form
    {
        public FormManual()
        {
            InitializeComponent();
            uC_InspCtr1.FromInit(1, "检测模组1");
            uC_InspCtr2.FromInit(2, "检测模组2");
            uC_InspCtr3.FromInit(3, "检测模组3");
            uC_InspCtr4.FromInit(4, "检测模组4");
            uC_CCD_Ctr1.Init(1, "CCD1",Kernel.motion);
            uC_CCD_Ctr2.Init(2, "CCD2", Kernel.motion);

            uC_InspCtr1.Load();
            uC_InspCtr2.Load();
            uC_InspCtr3.Load();
            uC_InspCtr4.Load();
            uC_CCD_Ctr1.Load();
            uC_CCD_Ctr2.Load();


            uC_LoadCVCtr1.Init(1,"入口CV1");
            uC_LoadCVCtr2.Init(2,"入口CV2");
            uC_LoadCVCtr1.Load();
            uC_LoadCVCtr2.Load();



            //uC_LoadCV1.SetInit("入口CV1",1);
            //uC_LoadCV2.SetInit("入口CV2", 2);
            //uC_InspCtr1.FromInit(1, "检测模组1");
            //uC_InspCtr2.FromInit(2, "检测模组2");


            //uC_InspCtr1.Load();
            //uC_InspCtr2.Load();
            //uC_LoadCV1.Load();
            //uC_LoadCV2.Load();



            //uC_ManualExcST1.Load();
            //uC_ManualExcTR1.Load();
            //uC_ManualSortST1.Load();
            //uC_ManualLDTR1.Load();
            //uC_ManualULDTR1.Load();
            //uC_ManualULDST1.Load();
            //uC_ManualLaserST1.Load();
            //uC_ManualLaserControl1.Load();
        }

        public void ShowForm()
        {
            this.Show();
            this.WindowState = FormWindowState.Normal;
            this.Activate();
        }

        private void FormManual_FormClosing(object sender, FormClosingEventArgs e)
        {
            this.Visible = false;
            e.Cancel = true;
        }
    }
}
